<?php
/**
 * Created by PhpStorm.
 * User: ai
 * Date: 2018/1/18
 * Time: 9:23
 */
use yii\grid\GridView;
use yii\helpers\Html;


$this->title = '我的案卷-智能阅卷 让阅卷更轻松';
$this->params['breadcrumbs'][] = ['label' => '上传案卷', 'url' => ['/yue-juan/index']];
$this->params['breadcrumbs'][] = $this->title;


?>

<div class="row">
    <div class="col-sm-offset-3 col-sm-6">
        <div class="generalocr-index">
            <label>我的案卷</label>
            <?= GridView::widget([
                'dataProvider' => $dataProvider,
                'filterModel' => $searchModel,
                'columns' => [
                    ['class' => 'yii\grid\SerialColumn'],
                    'id',

                    [
                        'attribute' => 'title',
                        'format' => 'raw',
                        'value' => function ($model) {
                            return Html::a($model->title, ['/yue-juan/scan-view', 'title' => $model->title]);
                        }
                    ],
                    [
                        'attribute' => 'user_id',
                        'value' => function ($model) {
                            return $model->uploader->realname;
                        }
                    ],
                    'created_at',
//            ['class' => 'yii\grid\ActionColumn'],
                ],
            ]); ?>
        </div>
    </div>
</div>
